package branch_and_price_vrptw;

public class TreeBB {
    // this is a linked tree list recording all the branching during Branch and Bound
    TreeBB father; // link to the node processed before branching
    TreeBB son0; // link to the son on the left of the tree (edge=0; first processed) => need it to compute the global lowerbound
    int branchFrom; // we branch on edges between cities => city origin of the edge
    int branchTo; // we branch on edges between cities => city destination of the edge
    int branchValue; // we branch on edges between cities => value of the branching (remove edge=0; set edge=1)
    double lowestValue; // lower bound on the solution if we start from this node (i.e. looking only down for this tree)
    boolean toplevel; // to compute the global lowerBound, need to know if everything above has been considered

    public TreeBB(TreeBB father, TreeBB son0, int branchFrom, int branchTo, int branchValue, double lowestValue, boolean toplevel) {
        this.father = father;
        this.son0 = son0;
        this.branchFrom = branchFrom;
        this.branchTo = branchTo;
        this.branchValue = branchValue;
        this.lowestValue = lowestValue;
        this.toplevel = toplevel;
    }

    public TreeBB() {
    }
}
